{% load static %}
<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>{% block title %}WLPlat{% endblock %}</title>
    <style>
        :root {
            --primary-blue: #3F51B5;
            --text-gray: #6D6D6D;
            --accent-yellow: #FFF8E5;
            --accent-purple: #E8E6F9;
        }

        body {
            min-height: 100vh;
            font-family: 'Microsoft YaHei', sans-serif;
            margin: 0;
            padding-top: 60px;
        }

        .nav-container {
            display: flex;
            justify-content: space-between;
            align-items: center;
            background-color: #ffffff;
            position: fixed;

            top: 0;
            left: 0;
            right: 0;
            z-index: 1000;
            padding: 16px 5%;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
        }

        .logo-link {
            margin-right: 30px;
            display: flex;
            align-items: center;
        }

        .nav-logo {
            height: 36px;
            width: auto;
            transition: transform 0.3s ease;
        }

        .nav-logo:hover {
            transform: scale(1.05);
        }

        .nav-links {
            display: flex;
            gap: 30px;
        }

        .nav-link {
            color: var(--text-gray);
            text-decoration: none;
            transition: all 0.3s;
        }

        .nav-link::after {
            content: '';
            display: block;
            width: 0;
            height: 2px;
            background: var(--primary-blue);
            transition: width 0.3s;
        }

        .nav-link:hover::after {
            width: 100%;
        }
.container my-4{
display: flex;
flex-direction: column;
align-items: center;
}

        .stats {
            display: flex;
            align-items: center;
            gap: 10px;
            color: var(--text-gray);
        }
    </style>
</head>

<body>
    <!-- 导航栏 -->
    <nav class="nav-container">
        <a href="{% url 'index' %}" class="logo-link">
            <!-- 假设 logo-home.png 放在 media 目录下 -->
            <img src="{% static 'media/logo-home.png' %}" alt="WLPlat" class="nav-logo">
        </a>
        <div class="nav-links">
            <a href="{% url 'index' %}" class="nav-link">首页</a>
            <a href="{% url 'visualize' %}" class="nav-link">可视化</a>
            <a href="{% url 'nlp_analysis' %}" class="nav-link">NLP 分析</a>
            <a href="{% url 'paper_polish' %}" class="nav-link">学术论文润色</a>
        </div>
        <div class="stats">
            {% if user.is_authenticated %}
                <a href="{% url 'profile' %}" class="nav-link">个人资料</a>
                <a href="{% url 'logout' %}" class="nav-link">退出登录</a>
            {% else %}
                <a href="{% url 'register' %}" class="nav-link">注册</a>
                <a href="{% url 'login' %}" class="nav-link">登录</a>
            {% endif %}
        </div>
    </nav>

    <div class="container my-4" style="display: flex;
    flex-direction: column;
    align-items: center;
    ">
        {% block content %}
        {% endblock %}
    </div>
</body>

</html>